function longest<Type extends { length: number }>(a: Type, b: Type) {
	if (a.length >= b.length) {
		return a;
	} else {
		return b;
	}
}
const longerArray = longest([1, 2], [2, 3, 4])
const longerString = longest('hello', 'ts')
// const notOk = longest(10, 100)
console.log(longerArray)
console.log(longerString)

